package com.int_tech.control.entity;

import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.*;
import java.util.Date;

/**
 * Created by liubochao on 2018/7/2.
 */
@Entity
@Table(name = "c_socket_get_resource")
@DynamicInsert
@DynamicUpdate
@Getter
@Setter
@ToString
@Accessors(chain = true)
public class SocketGetResource {

    @Id
    @GeneratedValue(strategy = GenerationType.AUTO)
    @Column(length = 8)
    private Integer id;

    //dataInfo
    private String dataString;

    //创建时间
    @Temporal(TemporalType.TIMESTAMP)
    @Column(updatable = false)
    private Date createTime;

    //修改时间
    @Temporal(TemporalType.TIMESTAMP)
    private Date updateTime;

    //同步处理状态（0.默认未处理;1.异常开关门处理完成；-1，异常开关门处理异常;
    // 2.装载率处理完成；-2.装载率处理异常；
    // 3.车辆行驶信息处理完成；-3.车辆行驶信息处理异常；
    // -99.数据处理异常待处理）
    private int status;
}
